package com.koo.modules.stock.entity;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.koo.common.base.entity.CommonEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

/**
 * 装斗清斗主表
 *
 * @author charlin
 * @email 136137465@qq.com
 * @date 2023-04-03 10:59:55
 */
@Data
@ApiModel("装斗清斗主表")
@TableName("stock_bucket_clear")
public class StockBucketClearEntity extends CommonEntity {
    private static final long serialVersionUID = 1L;

    @ExcelIgnore
    @TableId
    private Long clearId;

    @ColumnWidth(11)
    @ExcelProperty("装斗清斗单号")
    @ApiModelProperty(value = "装斗清斗单号")
    private String clearNo;

    @ColumnWidth(11)
    @ExcelProperty("单据日期")
    @ApiModelProperty(value = "单据日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date clearDate;

    @ColumnWidth(11)
    @ExcelProperty("审核人Id")
    @ApiModelProperty(value = "审核人Id")
    private Long auditorId;

    @ColumnWidth(11)
    @ExcelProperty("审核人")
    @ApiModelProperty(value = "审核人")
    private String auditor;

    @ColumnWidth(11)
    @ExcelProperty("审核状态")
    @ApiModelProperty(value = "审核状态")
    private Integer auditStatus;

    @ColumnWidth(11)
    @ExcelProperty("审核说明")
    @ApiModelProperty(value = "审核说明")
    private String auditNote;

    @ColumnWidth(11)
    @ExcelProperty("复核人id")
    @ApiModelProperty(value = "复核人id")
    private String checkId;

    @ColumnWidth(11)
    @ExcelProperty("复核人名字")
    @ApiModelProperty(value = "复核人名字")
    private String checkName;

    @ColumnWidth(11)
    @ExcelProperty("复核状态")
    @ApiModelProperty(value = "复核状态")
    private Integer checkStatus;

    @ColumnWidth(11)
    @ExcelProperty("复核说明")
    @ApiModelProperty(value = "复核说明")
    private String checkNote;

    @ExcelIgnore
    @TableField(exist = false)
    private List<StockBucketClearDetailEntity> itemList;

}
